package com.zbkj.crmeb.enums;

/**
 * x
 *
 * @author muyu.myw
 * @date 2020/9/28 18:58
 */
public enum ProcureStatusEnum {
    NO_PROCURE(1,"自建商品无需采购"),
    FOR_PROCURE(2,"待采购"),
    PROCURE(3, "已采购"),
    AUTO_PROCURE(4,"云仓商品订单自主发货");
    Integer type;
    String typeName;

    public Integer getType() {
        return type;
    }

    public String getTypeName() {
        return typeName;
    }

    private ProcureStatusEnum(Integer type, String typeName){
        this.type = type;
        this.typeName = typeName;
    }
    public static ProcureStatusEnum getTypeByCode(Integer type){
        if(type != null){
            for(ProcureStatusEnum val : ProcureStatusEnum.values()){
                if(val.type.equals(type)){
                    return val;
                }
            }
        }
        return null;
    }
}
